Stored Procedures [dbo].[asi_eSeriesInitialSettings]
Properties
PropertyValue
ANSI Nulls OnYes
Quoted Identifier OnYes
Parameters
NameData TypeMax Length (Bytes)
@RootPathvarchar(100)100
@VirtualDirectoryvarchar(100)100
@EmailAddressvarchar(100)100
@OrganizationNamevarchar(100)100
@OrganizationAbbrevvarchar(100)100
@WebCustomerTypevarchar(5)5
SQL Script
CREATE PROCEDURE [dbo].[asi_eSeriesInitialSettings]
      @RootPath varchar(100),
      @VirtualDirectory varchar(100),
      @EmailAddress varchar(100),
      @OrganizationName varchar(100),
      @OrganizationAbbrev varchar(100),
      @WebCustomerType varchar(5)
AS
BEGIN
   UPDATE System_Variable
      SET Value = @VirtualDirectory
    WHERE Name = 'VirtualDirectoryPath'

   UPDATE System_Variable
      SET Value = @RootPath
    WHERE Name in ('RootPath', 'SecurePath')
   
   UPDATE Website
      SET DefaultSectionURL = REPLACE(DefaultSectionURL,WebsiteRootURL,@RootPath)
    WHERE IsiMISWebsite = 0

   UPDATE Website
      SET WebsiteRootURL = @RootPath,
          SecureWebsiteRootURL = @RootPath
    WHERE IsiMISWebsite = 0

          
   UPDATE SystemConfig
      SET ParameterValue = @EmailAddress
    WHERE ParameterName in (
            'CompanySearchCreateAccountNotification',
            'SendToEmailOnAccountUpdate',
            'ContactUsEmailFrom',
            'ContactUsEmailTo',
            'Webmaster',
            'CreateAccountEmailFrom',
            'BasicFormEmailTo',
            'NoReplyOrganizationEmailAddress',
            'NewUserAddedFromEventRegistrationEmailTo',
            'EmailToSubmitComments',
            'OrderWebmaster',
            'BillingMembershipContactEmailAddress',
            'LogonChangesEmailFrom',
            'EmailFrom',
            'ProductSaleEmailTo')

   UPDATE SystemConfig
      SET ParameterValue = @OrganizationName
    WHERE ParameterName = 'OrganizationName'

   UPDATE SystemConfig
      SET ParameterValue = @OrganizationAbbrev
    WHERE ParameterName = 'OrganizationAbbrev'

   UPDATE SystemConfig
      SET ParameterValue = @VirtualDirectory + '/Images/'
    WHERE ParameterName = 'ImagesPath'

   UPDATE System_Params
      SET ShortValue = @WebCustomerType
    WHERE ParameterName = 'Member_Control.AnonymousSignUpMemberType'

   IF @@ROWCOUNT = 0
      INSERT INTO System_Params(ParameterName, ShortValue) VALUES ('Member_Control.AnonymousSignUpMemberType', @WebCustomerType)

END

GO
Uses